<!DOCTYPE html>
<html lang="en">

<head>
    <style type="text/css">
    body {
        background-color: #DDDDDD;
    }
    
    .user-panel {
        float: left;
        min-width: 18%;
        background-color: #fafcfe;
        margin-right: 20px;
        height: 855px;
    }
    
    .input-label {
        float: left;
        width: 125px;
        text-align: right;
    }
    
    .menu-panel {
        float: left;
        width: 45%;
        height: 855px;
        overflow: auto;
        background-color: #FFFFFF;
    }
    
    .cart-panel {
        float: left;
        width: 35%
    }
    
    .cart-table {
        width: 100%;
        text-align: center;
    }
    
    .order-panel {
        width: 30%;
        float: left;
        overflow: auto;
    }
    
    .header {
        background-color: black;
        height: 70px;
    }
    
    .header-title {
        margin-left: 20px;
        color: white;
        font-weight: 700;
        font-size: 60px;
    }
    
    .user-bar {
        float: right;
        color: white;
        position: relative;
        right: 3%;
        top: 40%;
    }
    
    .user-bar-name {
        font-size: 25px
    }
    
    .cart-total {
        float: right;
        margin-right: 40px;
    }
    
    .orders-btn-margin {
        margin-right: 10px;
    }
    </style>
    <meta charset="UTF-8">
    <title>Home</title>
</head>

<body>
    <script type="text/javascript" src="./../js/script.js"></script>
    <div class="header">
        <span class="header-title">
        Order System
        </span>
        <div class="user-bar" id="userDiv"></div>
    </div>
    <br/>
    <br/>
    <div>
        <div id="userPanel" class="user-panel">
            <div id="userRegister">
                <h3 style="text-align:center">
            Register
        </h3>
                <label class="input-label">User name : </label>
                <input type="text" id="regUserName" />
                <br/>
                <br/>
                <label class="input-label">Tel : </label>
                <input type="tel" id="regUserTel" onkeyup='this.value=this.value.replace(/\\D/g,"")'  onafterpaste='this.value=this.value.replace(/\D/g,")' />
                <br/>
                <br/>
                <label class="input-label">Password : </label>
                <input type="password" id="regUserPassword" />
                <br/>
                <br/>
                <label class="input-label">Confirm name : </label>
                <input type="password" id="regConUserPassword" />
                <br/>
                <br/>
                <div style="float:left;width:100%; text-align:center">
                    <button onclick="register()">Register</button>
                </div>
            </div>
            <br/>
            <br/>
            <div id="userLogin">
                <h3 style="text-align:center">
            Login
        </h3>
                <label class="input-label">User name : </label>
                <input type="text" id="userName" />
                <br/>
                <br/>
                <label class="input-label">Password : </label>
                <input type="password" id="password" />
                <br/>
                <br/>
                <div style="float:left;width:100%; text-align:center">
                    <button id="submitLogin" onclick="login()">Login</button>
                </div>
            </div>
        </div>
        <div id="menu" class="menu-panel">
        </div>
        <div class="cart-panel">
            <table id="cartTable" class="cart-table">
                <thead>
                    <tr>
                        <td></td>
                        <td>Name</td>
                        <td>Price</td>
                        <td>Quantity</td>
                        <td>Remove</td>
                    </tr>
                </thead>
            </table>
            <div class="cart-total">
                <h3>Total : <span id="cartTotal">0</span></h3>
                <button id="payBtn" onclick="checkout()" style="float: right;">Pay</button>
            </div>
        </div>
        <div id="orderList" class="order-panel">
        </div>
    </div>
</body>

</html>
